package com.moneywelcome.orderfacade;

import com.moneywelcome.orderfacade.dto.CommentDto;
import com.moneywelcome.orderfacade.dto.ReplyDto;
import com.moneywelcome.orderfacade.vo.CommentVo;
import com.moneywelcome.orderfacade.vo.ReplyVo;
import com.moneywelcome.results.PageResult;
import com.moneywelcome.results.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(
        contextId = "discussApi",//服务名字
        value = "invest-order" // 区分不同client
)
public interface DiscussApi {
    @GetMapping("/loadComment")
    Result<PageResult<CommentDto>> loadComment(@RequestParam("goldId") String goldId);

    @PostMapping("/comment")
    Result<CommentDto> comment(@RequestBody CommentVo commentVo);
    @PostMapping("/reply")
    Result<ReplyDto> reply(@RequestBody ReplyVo replyVo);
}
